home *** CD-ROM | disk | FTP | other *** search
/ Apple Developer Connection Student Program / ADC Tools Sampler CD Disk 3 1999.iso / Apple Development Tools / ToolServer 3.4.1.sit / ToolServer 3.4.1 / StartupTS < prev    next >
Text File  |  1996-03-06  |  10KB  |  282 lines

  1. #    StartupTS - ToolServer Startup File
  2. #
  3. #    Copyright Apple Computer, Inc. 1990-1996
  4. #    All Rights Reserved.
  5.  
  6. #     {BackgroundShell} - true for ToolServer
  7.             Export BackgroundShell
  8.  
  9. #    {Boot} - The boot disk.  (Predefined.)
  10.             Export Boot
  11.  
  12. #    {SystemFolder} - The directory that contains System & Finder.  (Predefined.)
  13.             Export SystemFolder
  14.  
  15. #    {ShellDirectory} - The directory that contains ToolServer.  (Predefined.)
  16.             Export ShellDirectory
  17.  
  18. #    {Active} - The active (topmost) window.  (Predefined.)
  19.             Export Active
  20.  
  21. #    {Target} - The target (previously active) window.  (Predefined.)
  22.             Export Target
  23.  
  24. #    {Worksheet} - The name of the Worksheet window.  (Predefined.)
  25.             Export Worksheet
  26.  
  27. #    {Status} - The result of the last command executed.  (Predefined.)
  28.             Export Status
  29.  
  30. #    {User} - Automatically defined to the name the appears in the Chooser.
  31.             Export User
  32.  
  33. #    {MPW} - The volume or folder containing the Macintosh Programmer's Workshop.
  34. #            If you put Toolserver outside the MPW folder (say on the desktop), 
  35. #            you should redefine this variable to the location of the MPW folder.
  36.             Set MPW "{ShellDirectory}"
  37.             Export MPW
  38.             
  39. #    {MPWVersion} - Version of MPW
  40.             Export MPWVersion
  41.  
  42. #    {ExtendWordSet}
  43.         Export ExtendWordSet
  44.         
  45. #    {InhibitMarkCopy}
  46.         Export InhibitMarkCopy
  47.         
  48. #    {NewKeyboardLayout}
  49.         Export NewKeyboardLayout
  50.         
  51. #    {ScreenUpdateDelay}
  52.         Export ScreenUpdateDelay
  53.         
  54. #    {ToolSleepTime}
  55.         Export ToolSleepTime
  56.  
  57. #    {Commands} - Directories to search for commands.  As of ETO 20 we have introduced
  58. #                    the concept of a user commands directory where you put your
  59. #                    personal commands.  We've also merged the tools and scripts
  60. #                    directories into a single directory called "Commands"
  61.             Set Commands ":"
  62.             If `Exists "{MPW}User Commands:"` 
  63.                 Set Commands "{Commands}","{MPW}User Commands:"
  64.             End
  65.             If `Exists "{MPW}Commands:"` 
  66.                 Set Commands "{Commands}","{MPW}Commands:"
  67.             End
  68.             If `Exists "{MPW}Tools:"` 
  69.                 Set Commands "{Commands}","{MPW}Tools:"
  70.             End
  71.             If `Exists "{MPW}Scripts:"` 
  72.                 Set Commands "{Commands}","{MPW}Scripts:"
  73.             End
  74.             Export Commands
  75.             
  76. #     {PrefsFolder} - Directory to search for userstartupTS and quitTS scripts. (Predefined.)
  77. #                    Toolserver looks in the {PrefsFolder} and then the {MPW} 
  78. #                    folder for startup and quit scripts.  {PrefsFolder} defaults to
  79. #                    {SystemFolder}Preferences:MPW.  You may change this here, 
  80. #                    or create an alias named MPW in the preferences folder to 
  81. #                    reference the folder where you keep your scripts.
  82.             Export PrefsFolder
  83.             
  84. #    {TempFolder}  - Directory for temporary items.   (Predefined.)
  85. #                    Toolserver may create some temporary items here.
  86. #                    Defaults to {PrefsFolder}TempTS.
  87.             Export TempFolder
  88.             
  89. #    {SysTempFolder}  - Directory for temporary items.   (Predefined.)
  90. #                    ToolServer may create some temporary items here.
  91. #                    Defaults to "{Boot}Temporary Items".
  92.             Export SysTempFolder
  93.         
  94. #    As of ETO 20 we are moving towards having interfaces and
  95. #    libraries optionally outside the MPW folder.
  96. #    The new behavior is to first look up one level from
  97. #    the mpw directory for the interfaces and libraries
  98.  
  99.     If `Exists "{MPW}:Interfaces&Libraries:"` 
  100.         Set InterfacesandLibrariesLocation "{MPW}:Interfaces&Libraries:"
  101.     Else
  102.         Set InterfacesandLibrariesLocation "{MPW}"
  103.     End
  104.  
  105. #    {AIncludes} - Directories to search for assembly language include files.            
  106.             Set AIncludes "{InterfacesandLibrariesLocation}Interfaces:AIncludes:"
  107.             Export AIncludes
  108.             
  109. #    {Libraries} - Directory that contains shared libraries.         
  110.             Set Libraries "{InterfacesandLibrariesLocation}Libraries:Libraries:"
  111.             Export Libraries
  112.             
  113. #    {CIncludes} - Directories to search for C include files.
  114.             Set CIncludes "{InterfacesandLibrariesLocation}Interfaces:CIncludes:"
  115.             Export CIncludes
  116.  
  117. #    {CLibraries} - Directory that contains C libraries.         
  118.             Set CLibraries "{InterfacesandLibrariesLocation}Libraries:CLibraries:"
  119.             Export CLibraries
  120.             
  121.             if not `exists "{InterfacesandLibrariesLocation}Libraries:CLibraries:"`
  122.                 set CLibraries "You have not installed the CLibraries for 68K development."
  123.             end
  124.                         
  125. #    {SCIncludes} - Directories to search for C include files.
  126.             Set SCIncludes "{InterfacesandLibrariesLocation}Interfaces:CIncludes:"
  127.             Export SCIncludes
  128.  
  129. #    {PPCCIncludes} - Directories to search for PowerPC include files.
  130.             Set PPCCIncludes "{InterfacesandLibrariesLocation}Interfaces:CIncludes:"
  131.             Export PPCCIncludes
  132.  
  133. #    {PPCLibraries} - Directory that contains PowerPC libraries. 
  134.             Set PPCLibraries "{InterfacesandLibrariesLocation}"Libraries:PPCLibraries:
  135.             Export PPCLibraries
  136.             
  137.             if not `exists "{InterfacesandLibrariesLocation}Libraries:PPCLibraries:"`
  138.                 set PPCLibraries "You have not installed the CLibraries for PowerPC development."
  139.             end
  140.  
  141. #    {PInterfaces} - Directories to search for Pascal interface files.
  142.             Set PInterfaces "{InterfacesandLibrariesLocation}Interfaces:PInterfaces:"
  143.             Export PInterfaces
  144.  
  145. #    {PLibraries} - Directory that contains Pascal libraries.        
  146.             Set PLibraries "{InterfacesandLibrariesLocation}Libraries:PLibraries:"
  147.             Export PLibraries
  148.             
  149.             if not `exists "{InterfacesandLibrariesLocation}Libraries:PLibraries:"`
  150.                 set PLibraries "You have not installed the Libraries for Pascal development."
  151.             end
  152.  
  153. #    {RIncludes} - Directory that contains Rez include files.
  154.             Set RIncludes "{InterfacesandLibrariesLocation}Interfaces:RIncludes:"
  155.             Export RIncludes
  156.  
  157. #    {CFM68KLibraries} - Directory that contains CFM-68K static link libraries.         
  158.             Set CFM68KLibraries "{InterfacesandLibrariesLocation}Libraries:CFM68KLibraries:"
  159.             Export CFM68KLibraries
  160.  
  161.             if not `exists "{InterfacesandLibrariesLocation}Libraries:CFM68KLibraries:"`
  162.                 set CFM68KLibraries "You have not installed the Libraries for CFM 68K development."
  163.             end
  164.             
  165. #    {SharedLibraries} - Directory that contains "fat" PEF-format import libraries.         
  166.             Set SharedLibraries "{InterfacesandLibrariesLocation}Libraries:SharedLibraries:"
  167.             Export SharedLibraries
  168.             
  169. #    {CaseSensitive} - If non-zero, pattern matching is case sensitive.
  170.             Set CaseSensitive 0
  171.             Export CaseSensitive
  172.  
  173. #    {SearchBackward} - If non-zero, search will go backwards.
  174.             Set SearchBackward 0
  175.             Export SearchBackward
  176.  
  177. #    {SearchWrap} - If non-zero, search will wrap.
  178.             Set SearchWrap 0
  179.             Export SearchWrap
  180.  
  181. #    {SearchType} - Specifies the default searching type.  (0/literal,
  182. #        1/word, 2/regular expression)
  183.             Set SearchType 0
  184.             Export SearchType
  185.  
  186. #    {Tab} - Default tab setting for new windows.
  187.             Set Tab 4
  188.             Export Tab
  189.  
  190. #    {Font} - Default Font for new windows.
  191.             Set Font MPW
  192.             Export Font
  193.  
  194. #    {FontSize} - Default font size for new windows.
  195.             Set FontSize 9
  196.             Export FontSize
  197.  
  198. #    {AutoIndent} - If non-zero, auto indentation will be the default for
  199. #        new windows.
  200.             Set AutoIndent 1
  201.             Export AutoIndent
  202.  
  203. #    {WordSet} - Character set that defines words for searches and double-clicks.
  204.             Set WordSet 'a-zA-Z_0-9'
  205.             Export WordSet
  206.  
  207. #    {PrintOptions} - Options used by the Print Window and Print Selection menus.
  208.             Set PrintOptions '-h'
  209.             Export PrintOptions
  210.             
  211. #    {Exit} - If non-zero, command files terminate after the first error.
  212.             Set Exit 1
  213.             Export Exit
  214.  
  215. #    {Echo} - If non-zero, commands are echoed before execution.
  216.             Set Echo 0
  217.             Export Echo
  218.  
  219. #    {Test} - If non-zero, tools and applications are not executed.
  220.             Set Test 0
  221.             Export Test
  222.  
  223. #    Commando Support
  224.              Export Windows
  225.              Export Aliases
  226.              Set Commando Commando
  227.             Export Commando
  228.  
  229. #    Aliases
  230.             Alias File Target
  231.  
  232. #    Clean up temporary files that are left over from a previous run.
  233.         set exit 0
  234.         (delete -i "{mpw}"MPW.pipe-≈) ≥ dev:null
  235.         set exit 1
  236.         
  237. #    The file UserStartupTS can be used to override definitions made in StartupTS,
  238. #    or to define additional variables, exports, and aliases.  The file should be
  239. #    located in the directory containing Toolserver, or in your preferences 
  240. #     folder.
  241.  
  242.             If "{PrefsFolder}" && "`Exists "{PrefsFolder}UserStartupTS"`"
  243.                 Execute "{PrefsFolder}UserStartupTS"
  244.             Else
  245.                 if `Exists "{ShellDirectory}UserStartupTS"`
  246.                     Execute "{ShellDirectory}UserStartupTS"
  247.                 End
  248.                 
  249.             End
  250.  
  251. #    Since UserStartup is distributed with MPW, you may want to have other
  252. #    startup files that will not be overwritten with a new release.
  253. #    Other personalized startup files may be named UserStartupTS•≈ - such as 
  254. #    "UserStartupTS•John" or "UserStartupTS•Tom"  (• is option-8), and placed
  255. #    in the preferences folder ({PrefsFolder}).  Alternately, you can
  256. #    place additional startup items in the "TS Startup Items" folder located
  257. #    in the directory containing ToolServer.  The items in the
  258. #    "TS Startup Items" folder do not have any special naming conventions, and
  259. #    will be executed in alphabetical order.  They can also be any type of
  260. #    executable entity, such as scripts, tools, and/or applications.
  261. #
  262. #    The following executes such files found in either place.
  263.  
  264.             If "{PrefsFolder}"
  265.                 For __Startup__i in `(Files -t 'TEXT' -f -s "{PrefsFolder}"UserStartupTS•≈ || Set Status 0) ≥ dev:null`
  266.                     Execute "{__Startup__i}"
  267.                 End
  268.             End
  269.  
  270.             For __Startup__i in `(Files -t 'TEXT' -f -s "{ShellDirectory}TS Startup Items:" || Set Status 0) ≥ dev:null`
  271.                 Execute "{__Startup__i}"
  272.             End
  273.  
  274.             # this method of running custom startup scripts is obsolete, and will be removed
  275.             # in a future version of this script.  Please move your UserStartupTS• scripts into
  276.             # the new :TS Startup Items: folder.
  277.             For __Startup__i in `(Files -t 'TEXT' -f -s "{ShellDirectory}"UserStartupTS•≈ || Set Status 0) ≥ dev:null`
  278.                 Execute "{__Startup__i}"
  279.             End
  280.  
  281.             Unset __Startup__i
  282.